import { mapGetters } from 'vuex'
// import axios from 'axios'

const statMixin = {
  computed: {
    ...mapGetters([
      'userInfo'
    ])
  },
  methods: {
    // 添加埋点数据函数
    addStat (id, name) {
      // let params = {
      //   data: {
      //     model_uid: '0002',
      //     user_id: this.userInfo.user_id + '',
      //     user_name: this.userInfo.user_nickname,
      //     phone: this.userInfo.user_name,
      //     factory_id: this.userInfo.tenant_id + '',
      //     factory_name: this.userInfo.company_name,
      //     button_id: id,
      //     button_name: name
      //   },
      //   func: 'client_click_event'
      // }

      // axios.post(process.env.STAT_URL + 'fill/fill/api', params)
    }
  }
}

export default statMixin
